home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 10 / AACD 10.iso / AACD / Magazine / Morphos / GCC / ppc-amigaos / include / powerup / ppcpragmas / datatypes_pragmas.h < prev    next >
C/C++ Source or Header  |  2000-02-28  |  10KB  |  355 lines

  1. /* Automatically generated header! Do not edit! */
  2.  
  3. #ifndef _PPCPRAGMA_DATATYPES_H
  4. #define _PPCPRAGMA_DATATYPES_H
  5. #ifdef __GNUC__
  6. #ifndef _PPCINLINE__DATATYPES_H
  7. #include <powerup/ppcinline/datatypes.h>
  8. #endif
  9. #else
  10.  
  11. #ifndef POWERUP_PPCLIB_INTERFACE_H
  12. #include <powerup/ppclib/interface.h>
  13. #endif
  14.  
  15. #ifndef POWERUP_GCCLIB_PROTOS_H
  16. #include <powerup/gcclib/powerup_protos.h>
  17. #endif
  18.  
  19. #ifndef NO_PPCINLINE_STDARG
  20. #define NO_PPCINLINE_STDARG
  21. #endif/* SAS C PPC inlines */
  22.  
  23. #ifndef DATATYPES_BASE_NAME
  24. #define DATATYPES_BASE_NAME DataTypesBase
  25. #endif /* !DATATYPES_BASE_NAME */
  26.  
  27. #define    AddDTObject(win, req, o, pos)    _AddDTObject(DATATYPES_BASE_NAME, win, req, o, pos)
  28.  
  29. static __inline LONG
  30. _AddDTObject(void *DataTypesBase, struct Window *win, struct Requester *req, Object *o, long pos)
  31. {
  32. struct Caos    MyCaos;
  33.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  34. //    MyCaos.M68kStart    =    NULL;
  35. //    MyCaos.M68kSize        =    0;
  36.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  37. //    MyCaos.PPCStart        =    NULL;
  38. //    MyCaos.PPCSize        =    0;
  39.     MyCaos.a0        =(ULONG) win;
  40.     MyCaos.a1        =(ULONG) req;
  41.     MyCaos.a2        =(ULONG) o;
  42.     MyCaos.d0        =(ULONG) pos;
  43.     MyCaos.caos_Un.Offset    =    (-72);
  44.     MyCaos.a6        =(ULONG) DataTypesBase;    
  45.     return((LONG)PPCCallOS(&MyCaos));
  46. }
  47.  
  48. #define    DisposeDTObject(o)    _DisposeDTObject(DATATYPES_BASE_NAME, o)
  49.  
  50. static __inline void
  51. _DisposeDTObject(void *DataTypesBase, Object *o)
  52. {
  53. struct Caos    MyCaos;
  54.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  55. //    MyCaos.M68kStart    =    NULL;
  56. //    MyCaos.M68kSize        =    0;
  57.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  58. //    MyCaos.PPCStart        =    NULL;
  59. //    MyCaos.PPCSize        =    0;
  60.     MyCaos.a0        =(ULONG) o;
  61.     MyCaos.caos_Un.Offset    =    (-54);
  62.     MyCaos.a6        =(ULONG) DataTypesBase;    
  63.     PPCCallOS(&MyCaos);
  64. }
  65.  
  66. #define    DoAsyncLayout(o, gpl)    _DoAsyncLayout(DATATYPES_BASE_NAME, o, gpl)
  67.  
  68. static __inline ULONG
  69. _DoAsyncLayout(void *DataTypesBase, Object *o, struct gpLayout *gpl)
  70. {
  71. struct Caos    MyCaos;
  72.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  73. //    MyCaos.M68kStart    =    NULL;
  74. //    MyCaos.M68kSize        =    0;
  75.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  76. //    MyCaos.PPCStart        =    NULL;
  77. //    MyCaos.PPCSize        =    0;
  78.     MyCaos.a0        =(ULONG) o;
  79.     MyCaos.a1        =(ULONG) gpl;
  80.     MyCaos.caos_Un.Offset    =    (-84);
  81.     MyCaos.a6        =(ULONG) DataTypesBase;    
  82.     return((ULONG)PPCCallOS(&MyCaos));
  83. }
  84.  
  85. #define    DoDTMethodA(o, win, req, msg)    _DoDTMethodA(DATATYPES_BASE_NAME, o, win, req, msg)
  86.  
  87. static __inline ULONG
  88. _DoDTMethodA(void *DataTypesBase, Object *o, struct Window *win, struct Requester *req, Msg msg)
  89. {
  90. struct Caos    MyCaos;
  91.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  92. //    MyCaos.M68kStart    =    NULL;
  93. //    MyCaos.M68kSize        =    0;
  94.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  95. //    MyCaos.PPCStart        =    NULL;
  96. //    MyCaos.PPCSize        =    0;
  97.     MyCaos.a0        =(ULONG) o;
  98.     MyCaos.a1        =(ULONG) win;
  99.     MyCaos.a2        =(ULONG) req;
  100.     MyCaos.a3        =(ULONG) msg;
  101.     MyCaos.caos_Un.Offset    =    (-90);
  102.     MyCaos.a6        =(ULONG) DataTypesBase;    
  103.     return((ULONG)PPCCallOS(&MyCaos));
  104. }
  105.  
  106. #ifndef NO_PPCINLINE_STDARG
  107. #define DoDTMethod(a0, a1, a2, tags...) \
  108.     ({ULONG _tags[] = { tags }; DoDTMethodA((a0), (a1), (a2), (Msg)_tags);})
  109. #endif /* !NO_PPCINLINE_STDARG */
  110.  
  111. #define    GetDTAttrsA(o, attrs)    _GetDTAttrsA(DATATYPES_BASE_NAME, o, attrs)
  112.  
  113. static __inline ULONG
  114. _GetDTAttrsA(void *DataTypesBase, Object *o, struct TagItem *attrs)
  115. {
  116. struct Caos    MyCaos;
  117.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  118. //    MyCaos.M68kStart    =    NULL;
  119. //    MyCaos.M68kSize        =    0;
  120.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  121. //    MyCaos.PPCStart        =    NULL;
  122. //    MyCaos.PPCSize        =    0;
  123.     MyCaos.a0        =(ULONG) o;
  124.     MyCaos.a2        =(ULONG) attrs;
  125.     MyCaos.caos_Un.Offset    =    (-66);
  126.     MyCaos.a6        =(ULONG) DataTypesBase;    
  127.     return((ULONG)PPCCallOS(&MyCaos));
  128. }
  129.  
  130. #ifndef NO_PPCINLINE_STDARG
  131. #define GetDTAttrs(a0, tags...) \
  132.     ({ULONG _tags[] = { tags }; GetDTAttrsA((a0), (struct TagItem *)_tags);})
  133. #endif /* !NO_PPCINLINE_STDARG */
  134.  
  135. #define    GetDTMethods(object)    _GetDTMethods(DATATYPES_BASE_NAME, object)
  136.  
  137. static __inline ULONG *
  138. _GetDTMethods(void *DataTypesBase, Object *object)
  139. {
  140. struct Caos    MyCaos;
  141.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  142. //    MyCaos.M68kStart    =    NULL;
  143. //    MyCaos.M68kSize        =    0;
  144.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  145. //    MyCaos.PPCStart        =    NULL;
  146. //    MyCaos.PPCSize        =    0;
  147.     MyCaos.a0        =(ULONG) object;
  148.     MyCaos.caos_Un.Offset    =    (-102);
  149.     MyCaos.a6        =(ULONG) DataTypesBase;    
  150.     return((ULONG *)PPCCallOS(&MyCaos));
  151. }
  152.  
  153. #define    GetDTString(id)    _GetDTString(DATATYPES_BASE_NAME, id)
  154.  
  155. static __inline STRPTR
  156. _GetDTString(void *DataTypesBase, unsigned long id)
  157. {
  158. struct Caos    MyCaos;
  159.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  160. //    MyCaos.M68kStart    =    NULL;
  161. //    MyCaos.M68kSize        =    0;
  162.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  163. //    MyCaos.PPCStart        =    NULL;
  164. //    MyCaos.PPCSize        =    0;
  165.     MyCaos.d0        =(ULONG) id;
  166.     MyCaos.caos_Un.Offset    =    (-138);
  167.     MyCaos.a6        =(ULONG) DataTypesBase;    
  168.     return((STRPTR)PPCCallOS(&MyCaos));
  169. }
  170.  
  171. #define    GetDTTriggerMethods(object)    _GetDTTriggerMethods(DATATYPES_BASE_NAME, object)
  172.  
  173. static __inline struct DTMethods *
  174. _GetDTTriggerMethods(void *DataTypesBase, Object *object)
  175. {
  176. struct Caos    MyCaos;
  177.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  178. //    MyCaos.M68kStart    =    NULL;
  179. //    MyCaos.M68kSize        =    0;
  180.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  181. //    MyCaos.PPCStart        =    NULL;
  182. //    MyCaos.PPCSize        =    0;
  183.     MyCaos.a0        =(ULONG) object;
  184.     MyCaos.caos_Un.Offset    =    (-108);
  185.     MyCaos.a6        =(ULONG) DataTypesBase;    
  186.     return((struct DTMethods *)PPCCallOS(&MyCaos));
  187. }
  188.  
  189. #define    NewDTObjectA(name, attrs)    _NewDTObjectA(DATATYPES_BASE_NAME, name, attrs)
  190.  
  191. static __inline Object *
  192. _NewDTObjectA(void *DataTypesBase, APTR name, struct TagItem *attrs)
  193. {
  194. struct Caos    MyCaos;
  195.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  196. //    MyCaos.M68kStart    =    NULL;
  197. //    MyCaos.M68kSize        =    0;
  198.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  199. //    MyCaos.PPCStart        =    NULL;
  200. //    MyCaos.PPCSize        =    0;
  201.     MyCaos.d0        =(ULONG) name;
  202.     MyCaos.a0        =(ULONG) attrs;
  203.     MyCaos.caos_Un.Offset    =    (-48);
  204.     MyCaos.a6        =(ULONG) DataTypesBase;    
  205.     return((Object *)PPCCallOS(&MyCaos));
  206. }
  207.  
  208. #ifndef NO_PPCINLINE_STDARG
  209. #define NewDTObject(a0, tags...) \
  210.     ({ULONG _tags[] = { tags }; NewDTObjectA((a0), (struct TagItem *)_tags);})
  211. #endif /* !NO_PPCINLINE_STDARG */
  212.  
  213. #define    ObtainDataTypeA(type, handle, attrs)    _ObtainDataTypeA(DATATYPES_BASE_NAME, type, handle, attrs)
  214.  
  215. static __inline struct DataType *
  216. _ObtainDataTypeA(void *DataTypesBase, unsigned long type, APTR handle, struct TagItem *attrs)
  217. {
  218. struct Caos    MyCaos;
  219.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  220. //    MyCaos.M68kStart    =    NULL;
  221. //    MyCaos.M68kSize        =    0;
  222.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  223. //    MyCaos.PPCStart        =    NULL;
  224. //    MyCaos.PPCSize        =    0;
  225.     MyCaos.d0        =(ULONG) type;
  226.     MyCaos.a0        =(ULONG) handle;
  227.     MyCaos.a1        =(ULONG) attrs;
  228.     MyCaos.caos_Un.Offset    =    (-36);
  229.     MyCaos.a6        =(ULONG) DataTypesBase;    
  230.     return((struct DataType *)PPCCallOS(&MyCaos));
  231. }
  232.  
  233. #ifndef NO_PPCINLINE_STDARG
  234. #define ObtainDataType(a0, a1, tags...) \
  235.     ({ULONG _tags[] = { tags }; ObtainDataTypeA((a0), (a1), (struct TagItem *)_tags);})
  236. #endif /* !NO_PPCINLINE_STDARG */
  237.  
  238. #define    PrintDTObjectA(o, w, r, msg)    _PrintDTObjectA(DATATYPES_BASE_NAME, o, w, r, msg)
  239.  
  240. static __inline ULONG
  241. _PrintDTObjectA(void *DataTypesBase, Object *o, struct Window *w, struct Requester *r, struct dtPrint *msg)
  242. {
  243. struct Caos    MyCaos;
  244.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  245. //    MyCaos.M68kStart    =    NULL;
  246. //    MyCaos.M68kSize        =    0;
  247.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  248. //    MyCaos.PPCStart        =    NULL;
  249. //    MyCaos.PPCSize        =    0;
  250.     MyCaos.a0        =(ULONG) o;
  251.     MyCaos.a1        =(ULONG) w;
  252.     MyCaos.a2        =(ULONG) r;
  253.     MyCaos.a3        =(ULONG) msg;
  254.     MyCaos.caos_Un.Offset    =    (-114);
  255.     MyCaos.a6        =(ULONG) DataTypesBase;    
  256.     return((ULONG)PPCCallOS(&MyCaos));
  257. }
  258.  
  259. #ifndef NO_PPCINLINE_STDARG
  260. #define PrintDTObject(a0, a1, a2, tags...) \
  261.     ({ULONG _tags[] = { tags }; PrintDTObjectA((a0), (a1), (a2), (struct dtPrint *)_tags);})
  262. #endif /* !NO_PPCINLINE_STDARG */
  263.  
  264. #define    RefreshDTObjectA(o, win, req, attrs)    _RefreshDTObjectA(DATATYPES_BASE_NAME, o, win, req, attrs)
  265.  
  266. static __inline void
  267. _RefreshDTObjectA(void *DataTypesBase, Object *o, struct Window *win, struct Requester *req, struct TagItem *attrs)
  268. {
  269. struct Caos    MyCaos;
  270.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  271. //    MyCaos.M68kStart    =    NULL;
  272. //    MyCaos.M68kSize        =    0;
  273.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  274. //    MyCaos.PPCStart        =    NULL;
  275. //    MyCaos.PPCSize        =    0;
  276.     MyCaos.a0        =(ULONG) o;
  277.     MyCaos.a1        =(ULONG) win;
  278.     MyCaos.a2        =(ULONG) req;
  279.     MyCaos.a3        =(ULONG) attrs;
  280.     MyCaos.caos_Un.Offset    =    (-78);
  281.     MyCaos.a6        =(ULONG) DataTypesBase;    
  282.     PPCCallOS(&MyCaos);
  283. }
  284.  
  285. #ifndef NO_PPCINLINE_STDARG
  286. #define RefreshDTObject(a0, a1, a2, tags...) \
  287.     ({ULONG _tags[] = { tags }; RefreshDTObjectA((a0), (a1), (a2), (struct TagItem *)_tags);})
  288. #endif /* !NO_PPCINLINE_STDARG */
  289.  
  290. #define    ReleaseDataType(dt)    _ReleaseDataType(DATATYPES_BASE_NAME, dt)
  291.  
  292. static __inline void
  293. _ReleaseDataType(void *DataTypesBase, struct DataType *dt)
  294. {
  295. struct Caos    MyCaos;
  296.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  297. //    MyCaos.M68kStart    =    NULL;
  298. //    MyCaos.M68kSize        =    0;
  299.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  300. //    MyCaos.PPCStart        =    NULL;
  301. //    MyCaos.PPCSize        =    0;
  302.     MyCaos.a0        =(ULONG) dt;
  303.     MyCaos.caos_Un.Offset    =    (-42);
  304.     MyCaos.a6        =(ULONG) DataTypesBase;    
  305.     PPCCallOS(&MyCaos);
  306. }
  307.  
  308. #define    RemoveDTObject(win, o)    _RemoveDTObject(DATATYPES_BASE_NAME, win, o)
  309.  
  310. static __inline LONG
  311. _RemoveDTObject(void *DataTypesBase, struct Window *win, Object *o)
  312. {
  313. struct Caos    MyCaos;
  314.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  315. //    MyCaos.M68kStart    =    NULL;
  316. //    MyCaos.M68kSize        =    0;
  317.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  318. //    MyCaos.PPCStart        =    NULL;
  319. //    MyCaos.PPCSize        =    0;
  320.     MyCaos.a0        =(ULONG) win;
  321.     MyCaos.a1        =(ULONG) o;
  322.     MyCaos.caos_Un.Offset    =    (-96);
  323.     MyCaos.a6        =(ULONG) DataTypesBase;    
  324.     return((LONG)PPCCallOS(&MyCaos));
  325. }
  326.  
  327. #define    SetDTAttrsA(o, win, req, attrs)    _SetDTAttrsA(DATATYPES_BASE_NAME, o, win, req, attrs)
  328.  
  329. static __inline ULONG
  330. _SetDTAttrsA(void *DataTypesBase, Object *o, struct Window *win, struct Requester *req, struct TagItem *attrs)
  331. {
  332. struct Caos    MyCaos;
  333.     MyCaos.M68kCacheMode    =    IF_CACHEFLUSHALL;
  334. //    MyCaos.M68kStart    =    NULL;
  335. //    MyCaos.M68kSize        =    0;
  336.     MyCaos.PPCCacheMode    =    IF_CACHEFLUSHALL;
  337. //    MyCaos.PPCStart        =    NULL;
  338. //    MyCaos.PPCSize        =    0;
  339.     MyCaos.a0        =(ULONG) o;
  340.     MyCaos.a1        =(ULONG) win;
  341.     MyCaos.a2        =(ULONG) req;
  342.     MyCaos.a3        =(ULONG) attrs;
  343.     MyCaos.caos_Un.Offset    =    (-60);
  344.     MyCaos.a6        =(ULONG) DataTypesBase;    
  345.     return((ULONG)PPCCallOS(&MyCaos));
  346. }
  347.  
  348. #ifndef NO_PPCINLINE_STDARG
  349. #define SetDTAttrs(a0, a1, a2, tags...) \
  350.     ({ULONG _tags[] = { tags }; SetDTAttrsA((a0), (a1), (a2), (struct TagItem *)_tags);})
  351. #endif /* !NO_PPCINLINE_STDARG */
  352.  
  353. #endif /* SASC Pragmas */
  354. #endif /* !_PPCPRAGMA_DATATYPES_H */
  355.